package pl.edu.pk.mech.kkbus.service;

import static pl.edu.pk.mech.kkbus.staticstrings.NameEntity.NAME_ENTITY_HISTORY_LOG;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;

import pl.edu.pk.mech.kkbus.model.HistoryLog;
import pl.edu.pk.mech.kkbus.repository.HistoryLogDAO;

public class HistoryLogService {
    @Autowired
    HistoryLogDAO historyLogDAO;
    
    public boolean createOrUpdateHistoryLog(HistoryLog historyLog) {
    	return historyLogDAO.createOrUpdate(historyLog, NAME_ENTITY_HISTORY_LOG, historyLogDAO);
    }
    
    public List<HistoryLog> getHistoryLogByIdUser(String idUser) {
        return historyLogDAO.getHistoryLogByIdUser(idUser);
    }  
}
